﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace _uitwerking__Algoritmiek
{
    public class code_GGD3
    {
        public int bewerkingen;

        public code_GGD3()
        {
            bewerkingen = 0;
        }

        public int Execute(int M, int N)
        {
            while (N != 0)
            {
                int R = M % N;
                bewerkingen++;
                M = N;
                N = R;
            } return M;
        }
    }
}
